package cn.tedu.charging.common.Bean;

import cn.tedu.charging.account.service.IChargingStationService;
import org.springframework.beans.factory.InitializingBean;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

/**
 * 初始化项目并向redis中存储数据库数据
 */
@Component
public class ChargingAfterInitializingBean implements InitializingBean {

    @Autowired
    private IChargingStationService service;

    @Override
    public void afterPropertiesSet() throws Exception {
        service.countListByStationId("InitializingBean");
    }
}
